﻿namespace Example
{
    using System;
    using System.Linq;

    using Dates;

    using Xunit;

    public sealed class DatesDatePeriodFacts
    {
        [Fact]
        public void op_GetOccurrences_DateTime_DateTime()
        {
            var start = new DateTime(2009, 09, 01);
            var end = new DateTime(2010, 09, 01);

            const int expected = 52;
            var actual = DatePeriod.Weekly.GetOccurrences(start, end).Count();

            Assert.Equal(expected, actual);
        }
    }
}